import request from '../request'

//用户登录
export function login(params) {
  return request({ url: '/admin/login/index',method: 'post',data: params})
}

export function reg(params) {
	return request({ url: '/admin/login/index',method: 'post',data: params})
}

export function setMobileCode(params) {
	return request({ url: '/admin/login/sendSms', method: 'post', data: params})
}

//用户退出
export function logout(params) {
  return request({ url: '/admin/login/logout',method: 'post',data: params})
}

//获取登录信息 菜单 路由组建
export function getUserInfo(params) {
  return request({ url: '/admin/login/getUserInfo',method: 'post',data: params})
}

//设置用户信息 菜单 路由组建
export function setUserInfo(params) {
	return request({ url: '/admin/login/setUserInfo',method: 'post',data: params})
}


export function fileList(params) {
	return request({ url: '/admin/file/getList',method: 'post',data: params})
}

//获取上传路径以及上传类型
export function upload(params) {
	return request({ url: '/admin/file/upload',method: 'post',data: params})
}

//删除文件
export function removeFile(params) {
	return request({ url: '/admin/file/remove',method: 'post',data: params})
}

//删除文件
export function getUserTypeList(params) {
	return request({ url: '/admin/login/getUserTypeList',method: 'post',data: params})
}

export function addGroup(params) {
	return request({ url: '/admin/file/addGroup',method: 'post',data: params})
}

export function groupList(params) {
	return request({ url: '/admin/file/getGroupList',method: 'post',data: params})
}

export function assocGroup(params) {
	return request({ url: '/admin/file/assocGroup',method: 'post',data: params})
}

export function deleteFilesGroup(params) {
	return request({ url: '/admin/file/deleteFilesGroup',method: 'post',data: params})
}

export function deleteGroup(params) {
	return request({ url: '/admin/file/deleteGroup',method: 'post',data: params})
}

//oss直传返回的文件写入库
export function createFile(params) {
	return request({ url: '/admin/file/createFile',method: 'post',data: params})
}

//获取验证码
export function captch(params) {
  return request({ url: '/Login/verify',method: 'post',data: params})
}


